package com.douqu.game.auth.database.mapper;

import com.douqu.game.core.database.model.OrderRecordModel;
import org.apache.ibatis.annotations.Param;

/**
 * @Author: Bean
 * @Description:
 * @Date: 2017-11-13 15:08
 */
public interface OrderRecordMapper {

    int findCount(@Param("objectIndex") String objectIndex,
                  @Param("tcd") String tcd);

    int insert(OrderRecordModel gmModel);

    Integer getTotalRechargeCount(@Param("objectIndex") String objectIndex,
                                  @Param("startTime") String startTime,
                                  @Param("endTime") String endTime);

    int findByOutTradeNoCount(@Param("outTradeNo") String outTradeNo);

    void update(OrderRecordModel orderRecordModel);

    OrderRecordModel findByOutTradeNo(@Param("outTradeNo") String outTradeNo);

    OrderRecordModel findByTcd(@Param("tcd") String tcd);

    OrderRecordModel findStatusOrder(@Param("objectIndex") String objectIndex,
                                     @Param("serverId") Integer serverId,
                                     @Param("status") Integer status);

}
